package cn.tedu.backend.portal.controller;


import cn.tedu.backend.portal.model.Attractions;
import cn.tedu.backend.portal.service.IAttractionsService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.List;

@RestController
@Slf4j
public class AttractionsController {
    @Resource
    private IAttractionsService service;

    @RequestMapping("/selectActivityCount")
    public List<Attractions> selectActivityCount(){
      System.out.println(service.selectActivityCount());
        return service.selectActivityCount();
    }

  @RequestMapping("/selectAttractionsById/{id}")
  public List<Attractions> selectAttractionsById(@PathVariable int id){
    return service.selectAttractionsById(id);
  }

//    @RequestMapping("/selectVolunteerCount")
//    public int selectVolunteerCount(){
//        return service.selectVolunteerCount();
//    }
//
//    @RequestMapping("/selectOthersCount")
//    public int selectOthersCount(){
//        return service.selectOthersCount();
//    }

}
